#ifndef CHOIXCONSO_H
#define CHOIXCONSO_H

#include <QWidget>
#include <QSqlDatabase>
#include <QSqlQuery>
#include <QStandardItemModel>
#include <qtedelegate.h>
#include <QList>

#include <QKeyEvent>

namespace Ui {
class ChoixConso;
}

class ChoixConso : public QWidget
{
    Q_OBJECT

public:
    explicit ChoixConso(QWidget *parent = 0);
    ~ChoixConso();

public slots:
    void reset();

signals:
    void bucquer(QList<int> idConso);
    void finBucquage();

protected:
    void keyPressEvent(QKeyEvent * event);

private:
    Ui::ChoixConso *ui;

    QSqlDatabase db;
    QStandardItemModel *model;

    QList<int> liste;
};

#endif // CHOIXCONSO_H
